//TODO a(61)
function a61(module, exports, a) {
    var i = a(23), s = a(3), r = a(2), n = a(21), o = a(60), l = function (e) {
        this.contDom = e.dom.cont, this.parentEl = e.dom.parentEl, this.active = e.active, this.coreVideo = e.coreVideo
    };
    s.extend(l, i);
    var d = {
        init: function () {
            this.playerData = this.manager.playerData, this.nodes = {
                pannel: this.parentEl.find(".js-pannel"),
                loading: this.parentEl.find(".hv_ico_loading"),
                seekTip: this.parentEl.find(".hv_fastslide"),
                seekTipImg: this.parentEl.find(".hv_ico_fastslide"),
                seekTipCurrentTime: this.parentEl.find(".js-seek-curtime"),
                seekTipTotalTime: this.parentEl.find(".js-seek-tottime"),
                seekTipBar: this.parentEl.find(".hv_fastslide_bar")
            }, this.pannelTouchable = new o(this.nodes.pannel[0], {isTargetNode: !0}), this.seekTotalTime = 180, this.seekTime = null, this.startSeekTime = null, this.seekDir = "", this.pannelWidth = 0, this.duration = 0, this.disable = !0, this.manager.evt.on("vjs_durationChange", this.onSetDuration, this), this.manager.evt.on(n.EVENT.RESIZE, this.onResize, this), r.Android || r.isPC || (this.pannelTouchable.on("touchstart", this.onPannelTouchStart, this), this.pannelTouchable.on("touchmove", this.onPannelTouchMove, this), this.pannelTouchable.on("touchend", this.onPannelTouchEnd, this)), this.onResize()
        }, onSetDuration: function (e) {
            this.duration = e.args[0], this.nodes.seekTipTotalTime[0].innerHTML = s.formatTime(this.duration)
        }, onResize: function () {
            this.pannelWidth = this.nodes.pannel.width(), this.disable = this.contDom.width() <= 310
        }, onPannelTouchStart: function () {
            clearTimeout(this.prepareSeekTime)
        }, onPannelTouchMove: function (e) {
            var t = this.manager.listener.get(n.PLAY_STATE);
            if ("init" != t && "chaneDefi" != t && "seeking" != t && !this.disable) {
                var a = this.pannelTouchable.currentStartDelta.x / this.pannelWidth;
                if (Math.abs(a) >= .15 && !this.active.isDrag && (this.active.isDrag = !0, this.nodes.seekTip[0].style.display = "block", this.nodes.loading[0].style.display = "none", this.manager.evt.trigger(n.EVENT.PLAYER_COMMAND, "pause")), this.active.isDrag) {
                    null == this.startSeekTime && (this.startSeekTime = this.coreVideo.getCurrentTime());
                    var i = e.args[1];
                    i.preventDefault();
                    var r = this.pannelTouchable.currentDelta.x;
                    if (Math.abs(r) < 2)return;
                    (!this.seekDir || "right" == this.seekDir && r <= 0 || "left" == this.seekDir && r > 0) && (r > 0 ? (this.nodes.seekTipImg.removeClass("hv_ico_returnback"), this.seekDir = "right") : (this.nodes.seekTipImg.addClass("hv_ico_returnback"), this.seekDir = "left")), this.seekTime = this.startSeekTime + a * this.seekTotalTime, this.seekTime = Math.max(0, this.seekTime), this.seekTime = Math.min(this.seekTime, this.duration), this.nodes.seekTipBar.setStyle("width", this.seekTime / this.duration * 100 + "%"), this.nodes.seekTipCurrentTime[0].innerHTML = s.formatTime(this.seekTime), this.manager.evt.trigger("vjs_updateSeekTime", this.seekTime)
                }
            }
        }, onPannelTouchEnd: function (e) {
            if (this.active.isDrag) {
                var t = e.args[1];
                t.stopPropagation(), this.startSeekTime = this.seekTime, this.prepareSeekTime = setTimeout(s.bind(function () {
                    this.nodes.seekTip[0].style.display = "none", this.active.isDrag = !1, this.startSeekTime = null, this.manager.evt.trigger(n.EVENT.PLAYER_COMMAND, "seek", this.seekTime), this.manager.evt.trigger("vjs_autoHidePannel")
                }, this), 500)
            }
        }
    };
    s.merge(l.prototype, d), module.exports = l
}

